<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <!--<script src="https://cdn.bootcss.com/jquery/3.4.1/core.js"></script>-->
    <script src="https://cdn.bootcss.com/jquery/3.4.1/jquery.js"></script>
    <style>
        *{
            margin: 0;
            padding: 0;
            list-style: none;
        }
        .menu{
            width: 500px;
            background: #ff6700;
            margin: 100px auto;

        }
        .menu>div{

            float: left;
            width: 100px;


        }
        .menu div div{
            border: 1px solid blueviolet;

        }
        .menu-ul{
            background: aquamarine;
            display: none;
        }
    </style>
</head>
<body>
<div class="menu">
    <div class="menu1">
        <div>一级菜单1</div>
        <ul class="menu-ul">
            <li>二级菜单1</li>
            <li>二级菜单1</li>
            <li>二级菜单1</li>
        </ul>
    </div>

    <div class="menu2">
        <div>一级菜单2</div>
        <ul class="menu-ul">
            <li>二级菜单2</li>
            <li>二级菜单2</li>
            <li>二级菜单2</li>
        </ul>
    </div>
    <div class="menu3">
        <div>一级菜单3</div>
        <ul class="menu-ul">
            <li>二级菜单3</li>
            <li>二级菜单3</li>
            <li>二级菜单3</li>
        </ul>
    </div>
</div>
<script>
    $(function () {
        $(".menu>div").hover(function () {
            $(this).children(".menu-ul").css("display","block");
        },function () {
            $(this).children(".menu-ul").css("display","none");
        })
    })
</script>
</body>
</html>